package com.qf.dao;

import com.qf.pojo.User;

import java.sql.SQLException;
import java.util.List;

/**
 * @Author AzureSky_X
 * @Date 2021/1/5 20:13
 * @Version 1.0
 */
public interface UserDao {
    //根据用户名查询用户信息
    User selectByUsername(String username);

    //查询所有用户信息
    List<User> selectAllUser();

    //删除用户
    int deleteUser(int id);

    //修改用户
    int updateUser(User user) throws SQLException;

    //根据id查询用户
    User selectUserById(int id) throws SQLException;

    //插入用户
    int insertUser(User user);

    //分页查询用户信息
    List<User> selectPage(int startPage, Integer pageSize) throws SQLException;

    //查询总条数
    Long selectCount() throws SQLException;
}
